package com.oc.claimobs.bb.gps;

import javax.microedition.location.Location;

public class LocationHelper {

	public static String getLatLong(Location location){
		
		if(location == null){
			return "";
		}
		
		StringBuffer sb = new StringBuffer();
		sb.append(System.currentTimeMillis());
		sb.append("|");
		sb.append(location.getQualifiedCoordinates().getLatitude());
		sb.append("|");
		sb.append(location.getQualifiedCoordinates().getLatitude());
		sb.append("|");		
		sb.append(location.getSpeed());
		sb.append("|");
		sb.append(location.getQualifiedCoordinates().getAltitude());
		sb.append("|");
		sb.append(location.getQualifiedCoordinates().getHorizontalAccuracy());
		sb.append("|");
		sb.append(location.getQualifiedCoordinates().getVerticalAccuracy());

		return sb.toString();
		
	}
	
}
